const homeIndex = r => require.ensure([], () => r(require('@/views/home/index')))
const homeMy = r => require.ensure([], () => r(require('@/views/home/my')))
const homeParty = r => require.ensure([], () => r(require('@/views/home/party')))
const homePartyDetail = r => require.ensure([], () => r(require('@/views/home/partyDetail')))
const homeCommunity = r => require.ensure([], () => r(require('@/views/home/community')))

export default [
    // 首页
    // {
    //     path: '/',
    //     redirect: {
    //         name: 'homeIndex'
    //     }
    // },
    {
        path: '/',
        name: 'homeIndex',
        component: homeIndex,
        // props: true,
        meta: {
        title: '首页'
        }
    },
    {
        path: '/index.html',
        redirect: {
        name: 'homeIndex'
        }
    },
    {
        path: '/index',
        name: 'homeIndex',
        component: homeIndex,
        // props: true,
        meta: {
        title: '首页'
        }
    },
    // 个人中心
    {
        path: '/my',
        name: 'homeMy',
        component: homeMy,
        // props: true,
        meta: {
        title: '个人中心',
        requireAuth: true
        }
    },
     // 党支部
     {
        path: '/party',
        name: 'homeParty',
        component: homeParty,
        // props: true,
        meta: {
        title: '党支部'
        }
    },
      // 文章详情
      {
        path: '/partyDetail',
        name: 'homePartyDetail',
        component: homePartyDetail,
        // props: true,
        meta: {
        title: '文章详情',
        requireAuth: false
        }
    },
     // 社区胶卷
     {
        path: '/community',
        name: 'homeCommunity',
        component: homeCommunity,
        // props: true,
        meta: {
        title: '社区胶卷',
        requireAuth: true
        }
    },
]